package com.yycx.module.bus.provider.service.hy.impl;

import com.yycx.module.bus.client.entity.hy.BusHyorderCustomReturn;
import com.yycx.module.bus.provider.mapper.hy.BusHyorderCustomReturnMapper;
import com.yycx.module.bus.provider.service.hy.BusHyorderCustomReturnService;
import com.yycx.common.mybatis.base.service.impl.BaseServiceImpl;
import com.yycx.common.mybatis.model.ResultBody;
import org.springframework.stereotype.Service;
import com.yycx.common.base.entity.EntityMap;
import com.yycx.common.mybatis.query.CriteriaQuery;
import org.springframework.transaction.annotation.Propagation;
import com.yycx.common.mybatis.query.CriteriaSave;
import org.springframework.transaction.annotation.Transactional;

/**
 * 客户回款接口实现类
 *
 * @author flyme
 * @date 2023-10-30
 */
@Service
@Transactional(rollbackFor = Exception.class)
public class BusHyorderCustomReturnServiceImpl extends BaseServiceImpl<BusHyorderCustomReturnMapper, BusHyorderCustomReturn> implements BusHyorderCustomReturnService {

    @Override
    public ResultBody beforeAdd(CriteriaSave cs, BusHyorderCustomReturn bhcr, EntityMap extra) {
        return ResultBody.ok();
    }



    @Override
    @Transactional(propagation = Propagation.NOT_SUPPORTED, readOnly = true)
    public ResultBody beforePageList(CriteriaQuery<BusHyorderCustomReturn> cq, BusHyorderCustomReturn bhcr, EntityMap requestMap) {
      cq.orderByDesc("bhcr.createTime");
      return ResultBody.ok();
    }
}
